import 'dart:convert';

import 'package:enterprise_v6_app/generated/json/base/json_field.dart';
import 'package:enterprise_v6_app/generated/json/scheduling_plan_entity.g.dart';

export 'package:enterprise_v6_app/generated/json/scheduling_plan_entity.g.dart';

///值班记录实体
@JsonSerializable()
class SchedulingPlanEntity {
  SchedulingPlanEntity();

  factory SchedulingPlanEntity.fromJson(Map<String, dynamic> json) => $SchedulingPlanEntityFromJson(json);

  /// app打卡状态：1-上班卡 2-下班卡 3-请假
  late int appClockStatus = 0;
  late String askForLeave = '';
  late String classesBeginDate = '';
  late String classesBeginDateRecord = '';
  late String classesColor = '';
  late String classesEndDate = '';
  late String classesEndDateRecord = '';
  late String onDutyLeader = '';
  late String classesId = '';
  late String classesIdName = '';
  late String classesName = '';
  late String clockInRemark = '';
  late String companyCode = '';
  late String createBy = '';
  late String createById = '';
  late String createDate = '';
  late String deleted = '';
  late String departmentId = '';

  /// 打卡状态:1-正常 2-缺班 3-早退 4-迟到 5-请假
  late int dutyResults = 0;
  late String id = '';
  late String onDutyDate = '';
  late String onDutyDateStr = '';
  late String onDutyLeaderTel = '';
  late String onDutyStatus = '';
  late String onDutyStatusName = '';
  late String dutyResultsName = '';
  late String personType = '';
  late String personTypeName = '';
  late String onDutyType = '';
  late String onDutyUserPhone = '';
  late String schedulingConfigId = '';
  late String updateBy = '';
  late String updateById = '';
  late String updateDate = '';
  late String userId = '';
  late String userName = '';

  Map<String, dynamic> toJson() => $SchedulingPlanEntityToJson(this);

  @override
  String toString() {
    return jsonEncode(this);
  }
}
